const mixinPage = {
    data() {
        return {
            // 查看示例链接前缀
            preHref: "https://gitee.com/guozia007/vue-handbook/blob/master/src/VueDemoPages/",
        }
    },
    computed: {
        // 动态生成查看示例的链接
        getHref() {
            // console.log('@@', this.$vnode.tag)
            let vindex = this.$vnode.tag.indexOf('V');
            let componentName = this.$vnode.tag.slice(vindex) + '.vue';
            return this.preHref + componentName;
        }
    }
}

export default mixinPage;